package ar.org.cfired.creditos.gui;
import org.jbpm.api.ProcessEngine;
import org.jbpm.api.ExecutionService;
import org.jbpm.api.TaskService;
import org.jbpm.api.HistoryService;
import org.jbpm.api.Configuration;

public class Contexto {
	private ProcessEngine processEngine;
	private TaskService taskService;
	private ExecutionService executionService;
	private HistoryService historyService;

	public Contexto() {
		this.processEngine = new Configuration().buildProcessEngine();
		this.executionService = processEngine.getExecutionService();
		this.taskService = processEngine.getTaskService();
		this.historyService = processEngine.getHistoryService();
	}
	
	public void setProcessEngine(ProcessEngine processEngine) {
		this.processEngine = processEngine;
	}
	public ProcessEngine getProcessEngine() {
		return(this.processEngine);
	}

	public void setExecutionService(ExecutionService executionService) {
		this.executionService = executionService;
	}
	public ExecutionService getExecutionService() {
		return(this.executionService);
	}	

	public void setTaskService(TaskService taskService) {
		this.taskService = taskService;
	}
	public TaskService getTaskService() {
		return(this.taskService);
	}	

	public void setHistoryService(HistoryService historyService) {
		this.historyService = historyService;
	}
	public HistoryService getHistoryService() {
		return(this.historyService);
	}	
	
}
